import VueRouter from 'vue-router'
import MemberComponent from './components/MemberComponent.vue'
import SearchComponent from './components/SearchComponent.vue'
import CartComponent from './components/CartComponent.vue'
import HomeComponent from './components/HomeComponent.vue'

// 3. 创建路由对象
var router = new VueRouter({
  routes: [
    {path:'/',component:HomeComponent},
    {path:'/home',component:HomeComponent},
    {path:'/cart',component:CartComponent},
    {path:'/search',component:SearchComponent},
    {path:'/member',component:MemberComponent}
  ],
  linkActiveClass:'mui-active'
})

// 把路由对象暴露出去
export default router